﻿#region Copyright (C) Sector7 Software Studio. All rights reserved
/*******************************************************************************************
 * Creation
 *      Author:         Wolf Lai
 *      Date:           2013/3/23 星期六 16:58:58
 *      Version:        
 * Modification 
 *      Author: 
 *      Date: 
 *      Description: 
 *      Version:
 *******************************************************************************************/
#endregion
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Sector7.Framework.Utility;
using Sector7.Framework.DataDictionary.CORS;

namespace Sector7.Framework.DataDictionary.Utility
{
    /// <summary>
    /// WCF客户端单例
    /// </summary>
    public class WcfClient
    {
        /// <summary>
        /// 客户端实例
        /// </summary>
        private static WcfClientUtil<ICoreService> m_client = null;

        /// <summary>
        /// 私有构造器
        /// </summary>
        private WcfClient()
        {
        }

        /// <summary>
        /// 获取WCF客户端实例
        /// </summary>
        /// <returns></returns>
        public static WcfClientUtil<ICoreService> GetInstance()
        {
            if (null == m_client)
            {
                m_client = new WcfClientUtil<ICoreService>();
            }

            return m_client;
        }
    }
}
